package hello;

public class Test6 {
	public static void main(String[] args) {
		/*int i,s,a,b,c;
		for(i=100;i<=999;i++){
			a=i/100;
			b=i%100/10;
			c=i%10;
			s=a*a*a+b*b*b+c*c*c;
			if(s==i)
			System.out.println(i);
		}*/
		
		
		int a,b,c,d,i;
		for(i=100;i<=999;i++)
		{
			a=i/100;
			b=i%100/10;
			c=i%10;
			d=a*a*a+b*b*b+c*c*c;
			if(d==i) System.out.println(d);
		}
	}
}
